# Copyright 2018-2019 Daniel 'grindhold' Brendle
#
# This file is part of libphexfile.
#
# libphexfile is free software: you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public License
# as published by the Free Software Foundation, either
# version 3 of the License, or (at your option) any later
# version.
#
# libphexfile is distributed in the hope that it will be
# useful, but WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
# PURPOSE. See the GNU Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with libphexfile.
# If not, see http://www.gnu.org/licenses/.

project('phexfile', 'vala', 'c', license:'LGPL')

pkgconfig = import('pkgconfig')

api = '0.2'
phexfile_version = api + '.0'

glib = dependency('glib-2.0')
gobject = dependency('gobject-2.0')
gio = dependency('gio-2.0')
json_glib = dependency('json-glib-1.0')

subdir('src')
subdir('test')

pkgconfig.generate(libraries : phexfile_lib,
                   version : phexfile_version,
                   name : 'phexfile',
                   filebase : meson.current_build_dir()+'/phexfile-'+api,
                   requires : 'glib-2.0 gobject-2.0 gio-2.0 json-glib-1.0',
                   subdirs: 'phexfile-'+api,
                   description : 'A library to parse and eventually write the simulation format of phex.',
                   install: true)

install_data('phexfile-'+api+'.deps', install_dir: get_option('datadir') + '/vala/vapi')


